package cup.proxy.app;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
import org.springframework.cloud.netflix.zuul.EnableZuulProxy;
import org.springframework.context.annotation.Bean;

import cup.proxy.app.filter.AccessFilter;

/**
 * 
 * @author zhiyi.zhao
 *
 */
@EnableZuulProxy
@EnableEurekaClient
@SpringBootApplication
public class ZuulServer 
{
	public static void main(String[] args) {
        SpringApplication.run(ZuulServer.class, args);
    }
	
	@Bean
    public AccessFilter accessFilter() {
        return new AccessFilter();
    }
}
